<!--隐私政策-->
<template>
  <view>
    <navBar v-if="isShowCustomNavBar" :navbarData.sync="navbarData"></navBar>
    <wxParse v-if="identifier" :preview.sync="preview" :identifier.sync="identifier"></wxParse></view>
</template>
<script>
import tip from '@/utils/tip';
import { CUSTOMER_INFO } from '@/utils/constant';
import WxParse from '@/components/wxparse/wxparse';
import NavBar from '../../components/common/navbar';
export default {
  config: {
    navigationBarTitleText: '隐私政策'
  },
  components: {
    wxParse: WxParse,
    navBar:NavBar
  },
  data() {
    return {
      identifier: 'privacy',
      preview: false,
      navbarData: {
        showCapsule: 1, //是否显示左上角图标   1表示显示    0表示不显示
        navbarTitle: '我的订单', //导航栏 中间的标题
        hideSearch:true,
        hideHome:true
      },
      isShowCustomNavBar: true,
      nowPages:''
    };
  },
  onLoad(option) {
    this.identifier = option.identifier ? option.identifier : this.identifier;
    this.preview = option.preview ? option.preview : false;
    // uni.setNavigationBarTitle({
    //   title: option.name
    // });
    this.navbarData.navbarTitle = option.name
    let pages = getCurrentPages();
    var currPage = pages[pages.length - 1]; //当前页面
    this.nowPages = currPage.route;
  },
  onShow() {
   getApp().cl_tracker.track('mini_program_view', {
         path:  this.nowPages,
         pageName: '隐私政策',
       }) 
  },
  computed: {
    storeName() {
      return this.$store.state.storeName;
    }
  }
};
</script>
